import fetch from 'common/src/utils/fetch'

/**
 * 添加
 */
export function addData(data) {
    return fetch({
        url: '/api/electionservice/elcRebuildChargeTimeSet/add',
        method: 'post',
        data: data
    });
}
/**
 * 修改
 */
export function updateData(data) {
    return fetch({
        url: '/api/electionservice/elcRebuildChargeTimeSet/update',
        method: 'post',
        data: data
    });
}
/**
 * 查询缴费设置
 */
export function getRebuildChargeTimeSet(calendarId,projId) {
    return fetch({
        url: `/api/electionservice/elcRebuildChargeTimeSet/getRebuildChargeTimeSet?calendarId=${calendarId}&projId=${projId}`,
        method: 'get'
    });
}

/**
 * 检查是否在缴费时间内
 */
export function checkTime(calendarId) {
    return fetch({
        url: `/api/electionservice/elcRebuildChargeTimeSet/check/${calendarId}`,
        method: 'get'
    });
}

